<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <link rel="stylesheet" href="plugin/swiper.css">
    <style>
        .swiper-container {
            width: 600px;
            height: 400px;
        }

        .swiper-pagination-bullet-active {
            background-color: #fff;
        }
    </style>
</head>

<body>
    <div class="swiper-container">
        <div class="swiper-wrapper">
            <div class="swiper-slide"><img src="images/01.png" alt=""></div>
            <div class="swiper-slide"><img src="images/02.png" alt=""></div>
            <div class="swiper-slide"><img src="images/03.png" alt=""></div>
        </div>
        <!-- 如果需要分页器 -->
        <div class="swiper-pagination"></div>


        <!-- 如果需要导航按钮 -->
        <div class="swiper-button-prev"></div>
        <div class="swiper-button-next"></div>

    </div>
    <script src="plugin/swiper.js"></script>
    <script>
        window.onload = function () {
            var mySwiper = new Swiper('.swiper-container', {
                autoplay:2000,
                loop: true,

                // 如果需要分页器
                pagination: '.swiper-pagination',
                paginationClickable:true,
                // 如果需要前进后退按钮
                nextButton: '.swiper-button-next',
                prevButton: '.swiper-button-prev',
            })
        }
    </script>
</body>

</html>